package com.example.framework;

import com.google.gson.annotations.SerializedName;

import java.util.List;

public class Weather {
    /**
     * reason : 查询成功!
     * result : {"city":"南京","realtime":{"temperature":"2","humidity":"83","info":"晴","wid":"00","direct":"东风","power":"3级","aqi":"97"},"future":[{"date":"2021-01-03","temperature":"0/10℃","weather":"多云","wid":{"day":"01","night":"01"},"direct":"东风"},{"date":"2021-01-04","temperature":"3/11℃","weather":"阴转小雨","wid":{"day":"02","night":"07"},"direct":"东风转北风"},{"date":"2021-01-05","temperature":"0/6℃","weather":"小雨转阴","wid":{"day":"07","night":"02"},"direct":"北风转东北风"},{"date":"2021-01-06","temperature":"-6/7℃","weather":"多云转小雨","wid":{"day":"01","night":"07"},"direct":"北风"},{"date":"2021-01-07","temperature":"-8/0℃","weather":"多云","wid":{"day":"01","night":"01"},"direct":"西北风"}]}
     * error_code : 0
     */
    private String reason;
    private Result result;
    @SerializedName("error_code")
    private int errorCode;

    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    public Result getResult() {
        return result;
    }

    public void setResult(Result result) {
        this.result = result;
    }

    public int getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(int errorCode) {
        this.errorCode = errorCode;
    }

    public static class Result {
        /**
         * city : 南京
         * realtime : {"temperature":"2","humidity":"83","info":"晴","wid":"00","direct":"东风","power":"3级","aqi":"97"}
         * future : [{"date":"2021-01-03","temperature":"0/10℃","weather":"多云","wid":{"day":"01","night":"01"},"direct":"东风"},{"date":"2021-01-04","temperature":"3/11℃","weather":"阴转小雨","wid":{"day":"02","night":"07"},"direct":"东风转北风"},{"date":"2021-01-05","temperature":"0/6℃","weather":"小雨转阴","wid":{"day":"07","night":"02"},"direct":"北风转东北风"},{"date":"2021-01-06","temperature":"-6/7℃","weather":"多云转小雨","wid":{"day":"01","night":"07"},"direct":"北风"},{"date":"2021-01-07","temperature":"-8/0℃","weather":"多云","wid":{"day":"01","night":"01"},"direct":"西北风"}]
         */

        private String city;
        private Realtime realtime;
        private List<Future> future;

        public String getCity() {
            return city;
        }

        public void setCity(String city) {
            this.city = city;
        }

        public Realtime getRealtime() {
            return realtime;
        }

        public void setRealtime(Realtime realtime) {
            this.realtime = realtime;
        }

        public List<Future> getFuture() {
            return future;
        }

        public void setFuture(List<Future> future) {
            this.future = future;
        }

        public static class Realtime {
            /**
             * temperature : 2
             * humidity : 83
             * info : 晴
             * wid : 00
             * direct : 东风
             * power : 3级
             * aqi : 97
             */

            private String temperature;
            private String humidity;
            private String info;
            private String wid;
            private String direct;
            private String power;
            private String aqi;

            public String getTemperature() {
                return temperature;
            }

            public void setTemperature(String temperature) {
                this.temperature = temperature;
            }

            public String getHumidity() {
                return humidity;
            }

            public void setHumidity(String humidity) {
                this.humidity = humidity;
            }

            public String getInfo() {
                return info;
            }

            public void setInfo(String info) {
                this.info = info;
            }

            public String getWid() {
                return wid;
            }

            public void setWid(String wid) {
                this.wid = wid;
            }

            public String getDirect() {
                return direct;
            }

            public void setDirect(String direct) {
                this.direct = direct;
            }

            public String getPower() {
                return power;
            }

            public void setPower(String power) {
                this.power = power;
            }

            public String getAqi() {
                return aqi;
            }

            public void setAqi(String aqi) {
                this.aqi = aqi;
            }
        }

        public static class Future {
            /**
             * date : 2021-01-03
             * temperature : 0/10℃
             * weather : 多云
             * wid : {"day":"01","night":"01"}
             * direct : 东风
             */

            private String date;
            private String temperature;
            private String weather;
            private Wid wid;
            private String direct;

            public String getDate() {
                return date;
            }

            public void setDate(String date) {
                this.date = date;
            }

            public String getTemperature() {
                return temperature;
            }

            public void setTemperature(String temperature) {
                this.temperature = temperature;
            }

            public String getWeather() {
                return weather;
            }

            public void setWeather(String weather) {
                this.weather = weather;
            }

            public Wid getWid() {
                return wid;
            }

            public void setWid(Wid wid) {
                this.wid = wid;
            }

            public String getDirect() {
                return direct;
            }

            public void setDirect(String direct) {
                this.direct = direct;
            }

            public static class Wid {
                /**
                 * day : 01
                 * night : 01
                 */

                private String day;
                private String night;

                public String getDay() {
                    return day;
                }

                public void setDay(String day) {
                    this.day = day;
                }

                public String getNight() {
                    return night;
                }

                public void setNight(String night) {
                    this.night = night;
                }
            }
        }
    }
}
